﻿<%@ Page Language="C#" AutoEventWireup="true" CodeBehind="Users_Form.aspx.cs" Inherits="ERPWebDemos.Forms.Users_Form" %>

<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">
           
<%@ Register Assembly="RuleCode.Common" Namespace="RuleCode.Controls" TagPrefix="cc1" %>

<html xmlns="http://www.w3.org/1999/xhtml" >
<head id="Head1" runat="server">
    <title></title>
    <link href="/CSS/Form_G.css" rel="stylesheet" type="text/css" />
    <link href="/CSS/dhtmlwindow.css" rel="stylesheet" type="text/css" />
</head>
<body>
    <form id="form1" runat="server">
    <div> 
        <div id="OperatorDiv">
            <a href="#" class="OperatorAnchor addData">增加</a>&nbsp;
            <a href="#" class="OperatorAnchor editData">修改</a>&nbsp;
            <a href="#" class="OperatorAnchor deleteData">删除</a>&nbsp;
        </div>
        <div id="FilterDiv">            
        </div>
        <div id="DataDiv">        
            <div id="NoDataDiv" runat="server"  class="NoDataDiv">对不起，没有找到符合您要求的数据</div>
            <asp:GridView ID="MainGridView" runat="server" AutoGenerateColumns="False" CssClass="MainGrid">
                  <Columns>
                      <asp:BoundField DataField="UserID" HeaderText="UserID"   SortExpression="UserID" />
                      <asp:BoundField DataField="Email" HeaderText="Email" SortExpression="Email" />                     
                  </Columns>  
            </asp:GridView>            
        </div>
        <div id="PageDiv">
            <cc1:WebPager ID="MainWebPager" runat="server" PageSize="20"  
                ControlToPaginate="MainGridView" CssClass="MainWebPager" 
                onpageindexchanged="MainWebPager_PageIndexChanged"/>
        </div>
    </div>

    <script src="/JS/dhtmlwindow.js" type="text/javascript"></script>
    <script src="/JS/jquery-1.3.2.min.js" type="text/javascript"></script>    
    <script type="text/javascript">
        $(document).ready(function() {
            $(".addData").click(function() {
                addFrame = dhtmlwindow.open('iframebox_add', 'iframe', 'Dialogs/UpdateUsers.aspx?type=add', '', 'width=480px,height=300px,center=1,top=100px,resize=1,scrolling=1');
            });
            $(".editData").click(function() {
                var currentRecid = "";
                if (currentRecid != "") {
                    editFrame = dhtmlwindow.open('iframebox_edit', 'iframe', 'Dialogs/UpdateUsers.aspx?type=edit&recid=' + currentRecid, '', 'width=480px,height=300px,center=1,top=100px,resize=1,scrolling=1');
                }
            });
            $(".deleteData").click(function() {
                var currentRecid = "";
                if (currentRecid != "") {
                    if (confirm("您确定要删除当前数据吗？")) {

                    } 
                }
            });
        });
    </script>
    </form>
</body>
</html>
